package com.aote.expression.paramprocessor;

import java.util.Map;

import com.aote.expression.Param;
import com.browsesoft.htmlcomponent.HTMLBasicComponent;
import com.browsesoft.user.User;

public class SelfAttrProcessor implements ParamProcessor {

	public String process(Param param, Map attributes, User loginUser,
			HTMLBasicComponent component) {
		Map map = param.getParams();
		String attrName = (String) map.get("attrname");
		if (attributes.get(attrName) == null) {
			System.out.println("参数没有值：" + attrName);
			return "";
			//throw new NoFitValueException(param);
		} else {
			return (String) attributes.get(attrName);
		}
	}
}
